import React from "react";
import ReactDOM from "react-dom";
import "./index.css";
import App from "./App";
import reportWebVitals from "./reportWebVitals";

import "antd/dist/antd.css";
// 在入口文件引入antd组件库的样式

//todo 1. 选择路由的模式 hash[hashchange]/history[popstate+history api]
import {
  BrowserRouter, // 值得就是使用history   /home  history是需要后端支持的
  HashRouter // 指的就是使用了hash模式    #/home
} from "react-router-dom";

ReactDOM.render(
  <React.StrictMode>
    <BrowserRouter>
      <App />
    </BrowserRouter>
  </React.StrictMode>,
  document.getElementById("root")
);

// If you want to start measuring performance in your app, pass a function
// to log results (for example: reportWebVitals(console.log))
// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals
reportWebVitals();
